let Main = () => import("@/views/Main");
export default [
    //1---首页
    {
        path: "home",
        name: "home",
        component: () => import('../views/Home.vue'),
        meta: {
            title: "home",
            icon: "asael-icon-s-home",
        }
    },
    // 2---运营管理
    {
        path: "operatemanage",
        name: "operatemanage",
        component: Main,
        meta: {
            title: "yunyin.operatemanage",
            icon: "el-icon-s-data",
        },
        children: [
            {
                path: "order",  //订单管理
                name: "order",
                component: () => import('@/views/operationmanage/Order.vue'),
                meta: {
                    title: "yunyin.order"
                }
            },
            {
                path: "comment",   //评论管理
                name: "comment",
                component: () => import('@/views/operationmanage/Comment.vue'),
                meta: {
                    title: "yunyin.comment"
                }
            },
            {
                path: "freight",  //运费管理
                name: "freight",
                component: () => import('@/views/operationmanage/Freight.vue'),
                meta: {
                    title: "yunyin.freight"
                }
            },
        ]
    },
    // 3---商品管理
    {
        path: "shoppmanage",
        name: "shoppmanage",
        component: Main,
        meta: {
            title: "product.shoppmanage",
            icon: "el-icon-sell",
        },
        children: [
            {
                path: "product",  //商品列表
                name: "product",
                component: () => import('@/views/commoditymanage/ProductList.vue'),
                meta: {
                    title: "product.product"
                }
            },
            {
                path: "group",  //团购管理
                name: "group",
                component: () => import('@/views/commoditymanage/GroupPurchase.vue'),
                meta: {
                    title: "product.group"
                }
            },
            {
                path: "category",  //类目管理
                name: "category",
                component: () => import('@/views/commoditymanage/Category.vue'),
                meta: {
                    title: "product.category"
                }
            },
            {
                path: "create",  //商品列表--创建
                name: "create",
                component: () => import('@/views/commoditymanage/Create.vue'),
                meta: {
                    title: "product.create",
                    hide: false, //是否显示在左侧菜单栏
                    keepAlive: true, //缓存组件
                }
            },
            {
                path: "edit/:id",  //商品列表--创建
                name: "edit",
                component: () => import('@/views/commoditymanage/Edit.vue'),
                meta: {
                    title: "product.edit",
                    hide: false  //是否显示在左侧菜单栏
                }
            },
        ]
    },
    //4--- 推广管理
    {
        path: "spreadmanage",
        name: "spreadmanage",
        component: Main,
        meta: {
            title: "tuiguan.spreadmanage",
            icon: "el-icon-bangzhu",
        },
        children: [
            {
                path: "adver", //广告管理
                name: "adver",
                component: () => import('@/views/promotionmanage/Advertising.vue'),
                meta: {
                    title: "tuiguan.adver"
                }
            },
            {
                path: "coupon", //优惠券管理
                name: "coupon",
                component: () => import('@/views/promotionmanage/Coupon.vue'),
                meta: {
                    title: "tuiguan.coupon"
                }
            },
        ]
    },
    // 5---用户管理
    {
        path: "usermanage",
        name: "usermanage",
        component: Main,
        meta: {
            title: "user.usermanage",
            icon: "el-icon-user-solid",
        },
        children: [
            {
                path: "member", //会员管理
                name: "member",
                component: () => import('@/views/usermanage/Member.vue'),
                meta: {
                    title: "user.member"
                }
            },
            {
                path: "address", //地址管理
                name: "address",
                component: () => import('@/views/usermanage/Address.vue'),
                meta: {
                    title: "user.address"
                }
            },
        ]
    },
    // 6---系统管理
    {
        path: "lineagemanage",
        name: "lineagemanage",
        component: Main,
        meta: {
            title: "system.lineagemanage",
            icon: "el-icon-setting",
        },
        children: [
            {
                path: "system",  //系统配置
                name: "system",
                component: () => import('@/views/systemmanage/SystemLayout.vue'),
                meta: {
                    title: "system.system"
                }
            },
            {
                path: "conser",  //管理员
                name: "conser",
                component: () => import('@/views/systemmanage/Conservator.vue'),
                meta: {
                    title: "system.conser"
                }
            },
            {
                path: "operate",  //操作日志
                name: "operate",
                component: () => import('@/views/systemmanage/Operate.vue'),
                meta: {
                    title: "system.operate"
                }
            },
            {
                path: "role",  //角色管理
                name: "role",
                component: () => import('@/views/systemmanage/RoleManage.vue'),
                meta: {
                    title: "system.role"
                }
            },
        ]
    }

]

